package cn.itsource.org.service;

import cn.itsource.basic.util.PageList;
import cn.itsource.org.domain.Department;
import cn.itsource.org.query.DepartmentQuery;

import java.util.List;

public interface IDepartmentService {

    /**
     * 保存数据
     * @param department
     */
    void add(Department department);

    /**
     * 修改数据
     * @param department
     */
    void update(Department department);

    /**
     * 删除数据
     * @param id
     */
    void delete(Long id);

    /**
     * 查询一条数据
     * @param id
     * @return
     */
    Department queryById(Long id);

    /**
     * 查询所有数据
     * @return
     */
    List<Department> queryAll();


    /**
     * 分页查询
     *  + 高级
     * @param query
     * @return
     */
    PageList<Department> queryPage(DepartmentQuery query);

    /**
     * 批量删除
     */
    void deleteByIds(Long[] ids);



}
